package com.zzyl.controller;


import com.zzyl.base.PageResponse;
import com.zzyl.base.ResponseResult;
import com.zzyl.entity.ConsultationRecord;
import com.zzyl.service.ConsultationRecordService;
import com.zzyl.vo.ContractVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@Api(value = "退住咨询")
@RestController
@RequestMapping("/consultation-record")
public class ConsultationRecordController {

    @Resource
    private ConsultationRecordService service;

    @ApiOperation("查询退住咨询")
    @GetMapping("/pageQuery")
    public ResponseResult<PageResponse<ConsultationRecord>> query(
            String name,
            String phone,
            Integer type,
            Integer pageNum,
            Integer pageSize
    ) {
        PageResponse<ConsultationRecord> page = service.query(name, phone, type, pageNum, pageSize);
        return ResponseResult.success(page);
    }

//    @ApiOperation("新增")
}
